// 封装素材管理接口
import axios from '@/utils/request'
// 1.获取素材接口
export const getImages = function (params) {
  return axios({
    url: '/mp/v1_0/user/images',
    method: 'GET',
    params
  })
}
// 2.切换图片的收藏接口
export const switchCollect = function (id, collect) {
  return axios({
    url: `/mp/v1_0/user/images/${id}`,
    method: 'PUT',
    data: {
      collect
    }
  })
}
// 3.删除素材接口
export const deleteimage = function (id) {
  return axios({
    url: `/mp/v1_0/user/images/${id}`,
    method: 'DELETE'
  })
}
